package com.woniuxy.controller;

import com.woniuxy.pojo.User;
import com.woniuxy.service.UserService;
import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;


@Controller
public class LoginController {
    private Logger logger=Logger.getLogger(this.getClass());
    @Autowired
    private UserService userService;
    @PostMapping(value = "/login")
    public void login(@RequestBody User user, HttpSession session,
                      HttpServletRequest request){
        logger.info("用户名:"+user.getTelephone());
        logger.info("密码:"+user.getPassword());
    }
}
